﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace LanDBom.Models.Procure
{
    public class Modlfy_Nda_shen
    {
        LDbaseEntities db = new LDbaseEntities();
        public Formation Getnda(string nda_wuliao)
        {
            Formation inf = db.Formation.SingleOrDefault(x => x.FM_name == nda_wuliao);

            return inf;
        }

        public int ChangeInf_huip(Formation nda)
        {
            Formation Nda = Getnda(nda.FM_name);
            if (Nda != null)
            {
                Nda.FM_kong = nda.FM_kong;
                db.Entry(Nda).State = System.Data.Entity.EntityState.Modified;
            }
            return db.SaveChanges();
        }

     
    }
}